package com.zhongyouyun.cqyc.service.imp;

import com.zhongyouyun.cqyc.model.ModuleSetModel;
import com.zhongyouyun.cqyc.mapper.ModuleSetMapper;
import com.zhongyouyun.cqyc.pojo.ModuleSetPojo;
import com.zhongyouyun.cqyc.service.ModuleSetService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;

import java.util.List;

/**
 * @Author: shenyi
 * @Date: 2023-10-20
 * @Description: 模块设置服务实现类
 */
@Service
@Transactional(rollbackFor = Exception.class)
public class ModuleSetServiceImpl extends ServiceImpl<ModuleSetMapper, ModuleSetModel> implements ModuleSetService {
    /*
     * @Author: shenyi
     * @Date: 2021-09-08
     * @Description: 分页查询
     * @param page 分页数据  lambdaQueryWrapper where 条件 和排序
     */
    @Override
    public IPage<ModuleSetModel> selectPage(Page<ModuleSetModel> page, QueryWrapper<ModuleSetModel> queryWrapper) {
        return this.baseMapper.selectPage(page, queryWrapper);
    }


    /*
     * @Author: shenyi
     * @Date: 2021-09-08
     * @Description: 查询全部
     * @param   lambdaQueryWrapper where 条件 和排序
     */
    @Override
    public List<ModuleSetModel> selectList(QueryWrapper<ModuleSetModel> queryWrapper) {
        return this.baseMapper.selectList(queryWrapper);
    }

    @Override
    public IPage<ModuleSetPojo> selectPojoPage(Page page, QueryWrapper queryWrapper) {
        return this.baseMapper.selectPojoPage(page, queryWrapper);
    }
}
